const express = require('express');
const app = express();
const router = express.Router();
const bodyParser = require('body-parser');
const useBodyParser = bodyParser.urlencoded({
    extended: true,
});
app.use(useBodyParser);

router.post('/user', (req, res) => {
    console.log('req.url->', req.body);
    res.send({
        data: [
            { name: 'post' },
            { name: 'post' },
            { name: 'post' },
            { name: 'post' },
            { name: 'post' },
        ],
        msg: '请求数据成功',
        statusCode: 200,
    });
});
module.exports = router;
